package org.demo.patten.visitor;

/**
 * @author zhuj
 * @date 2025/3/29
 * @apiNote
 */
public class File implements FileSystemElement {
    private String name;
    private int size; // 单位：KB
    public File(String name, int size) {
        this.name = name;
        this.size = size;
    }
    public String getName() { return name; }
    public int getSize() { return size; }
    public void accept(Visitor visitor) {
        visitor.visit(this);
    }
}
